home *** CD-ROM | disk | FTP | other *** search
/ Winzipper / Winzipper_ISO.iso / nt4.0 server / DRVLIB.NIC / 3C527 / OEMSETUP.INF < prev   
INI File  |  1996-07-31  |  24KB  |  642 lines

  1. [Identification]
  2.     OptionType              = NetAdapter
  3.  
  4. [PlatformsSupported]
  5.     MCA
  6.  
  7. [LanguagesSupported]
  8.     ENG
  9.  
  10. [Options]
  11.     Elink527
  12.  
  13. [OptionsTextENG]
  14.     Elink527                = "3Com 3C527 Etherlink/MC 32 Adapter"
  15.  
  16. [FileConstants]
  17.     UtilityInf              = "UTILITY.INF"
  18.     subroutineinf           = "SUBROUTN.INF"
  19.     SoftwareType            = "driver"
  20.     Exit_Code               = 0
  21.     NetEventDLL             = "%SystemRoot%\System32\netevent.dll"
  22.     IoLogMsgDLL             = "%SystemRoot%\System32\IoLogMsg.dll"
  23.     Elink527_1BYTE          = 65
  24.     Elink527_2BYTE          = 0
  25.     Manufacturer            = "Microsoft"
  26.     ProductMajorVersion     = "3"
  27.     ProductMinorVersion     = "1"
  28.     ProductVersion          = $(ProductMajorVersion)"."$(ProductMinorVersion)
  29.     ProductSoftwareName     = "Elink527"
  30.     ProductSoftwareTitle    = "3Com 3C527 Etherlink/MC 32 Adapter Driver"
  31.     ProductSoftwareImagePath = "\SystemRoot\system32\drivers\Elink527.sys"
  32.     NetRuleSoftwareType     = "Elink527Sys ndisDriver Elink527Driver"
  33.     NetRuleSoftwareUse      = $(SoftwareType)
  34.     NetRuleSoftwareBindForm = """Elink527Sys"" yes no container"
  35.     NetRuleSoftwareClass    = {"Elink527Driver basic"}
  36.     NetRuleSoftwareBindable = {"Elink527Driver Elink527Adapter non exclusive 100"}
  37.     ProductHardwareName     = "Elink527"
  38.     ProductHardwareTitle    = "3Com 3C527 Etherlink/MC 32 Adapter"
  39.     NetRuleHardwareType     = "Elink527 Elink527Adapter"
  40.     NetRuleHardwareBindForm = " yes yes container"
  41.     NetRuleHardwareClass    = {"Elink527Adapter basic"}
  42.     ProductKeyName          = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion"
  43.     ParamKeyName            = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters"
  44.  
  45. [GeneralConstants]
  46.     from                    = ""
  47.     to                      = ""
  48.     ExitCodeOk              = 0
  49.     ExitCodeCancel          = 1
  50.     ExitCodeFatal           = 2
  51.     KeyNull                 = ""
  52.     MAXIMUM_ALLOWED         = 33554432
  53.     RegistryErrorIndex      = NO_ERROR
  54.     KeyProduct              = ""
  55.     KeyParameters           = ""
  56.     TRUE                    = 1
  57.     FALSE                   = 0
  58.     NoTitle                 = 0
  59.     ExitState               = "Active"
  60.     OldVersionExisted       = $(FALSE)
  61.     DriverPath              = $(!STF_NTPATH)\drivers
  62.  
  63. [FileConstantsENG]
  64.     ProCaption              = "Windows NT Setup"
  65.     ProCancel               = "Cancel"
  66.     ProCancelMsg            = "Windows NT Networking is not correctly installed.  "+
  67.                               "Are you sure you want to cancel copying files?"
  68.     ProCancelCap            = "Network Setup Message"
  69.     ProText1                = "Copying:"
  70.     ProText2                = "To:"
  71.     FunctionTitle           = "3Com 3C527 Etherlink/MC 32 Adapter Card Setup"
  72.     ProductSoftwareDescription = "3Com 3C527 Etherlink/MC 32 Adapter Driver"
  73.     ProductHardwareDescription = "3Com 3C527 Etherlink/MC 32 Adapter"
  74.     CANNOT_FIND_ANY_CARD       = "Network card is not present in the system"
  75.  
  76. [DialogConstantsENG]
  77.     Help                    = "&Help"
  78.     Exit                    = "&Cancel"
  79.     OK                      = "&OK"
  80.     HelpContext             = ""
  81.     Continue                = "C&ontinue"
  82.     Cancel                  = "C&ancel"
  83.  
  84. [date]
  85.     Now                     = {} ? $(!LIBHANDLE) GetSystemDate
  86.  
  87. [FileDependentDlgENG]
  88.  
  89. [Identify]
  90.     read-syms Identification
  91.     set Status     = STATUS_SUCCESSFUL
  92.     set Identifier = $(OptionType)
  93.     set Media      = #("Source Media Descriptions", 1, 1)
  94.     Return $(Status) $(Identifier) $(Media)
  95.  
  96. [ReturnOptions]
  97.     set Status         = STATUS_FAILED
  98.     set OptionList     = {}
  99.     set OptionTextList = {}
  100.     set LanguageList   = ^(LanguagesSupported, 1)
  101.     Ifcontains(i) $($0) in $(LanguageList)
  102.         ifstr(i) $($1) == ""
  103.            goto returnoptions
  104.         endif
  105.         set PlatformList = ^(PlatformsSupported, 1)
  106.         Ifcontains(i) $($1) in $(PlatformList)
  107.            goto returnoptions
  108.         else
  109.            set Status = STATUS_NOTSUPPORTED
  110.            goto finish_ReturnOptions
  111.         endif
  112.     else
  113.         set Status = STATUS_NOLANGUAGE
  114.         goto finish_ReturnOptions
  115.     endif
  116.  
  117. returnoptions = +
  118.     set OptionList     = ^(Options, 1)
  119.     set OptionTextList = ^(OptionsText$($0), 1)
  120.     set Status         = STATUS_SUCCESSFUL
  121.  
  122. finish_ReturnOptions = +
  123.     Return $(Status) $(OptionList) $(OptionTextList)
  124.  
  125. [InstallOption]
  126.     set Option       = $($1)
  127.     set SrcDir       = $($2)
  128.     set AddCopy      = $($3)
  129.     set DoCopy       = $($4)
  130.     set DoConfig     = $($5)
  131.     set LanguageList = ^(LanguagesSupported, 1)
  132.     Ifcontains(i) $($0) NOT-IN $(LanguageList)
  133.         Return STATUS_NOLANGUAGE
  134.     endif
  135.     set-subst LF = "\n"
  136.     read-syms GeneralConstants
  137.     read-syms FileConstants
  138.     read-syms DialogConstants$(!STF_LANGUAGE)
  139.     read-syms FileConstants$(!STF_LANGUAGE)
  140.     detect date
  141.     set-title  $(FunctionTitle)
  142.     set to   = Begin
  143.     set from = Begin
  144.     set CommonStatus = STATUS_SUCCESSFUL
  145.     EndWait
  146.  
  147. Begin = +
  148.     Ifstr(i) $(!NTN_InstallMode) == deinstall
  149.         set StartLabel = removeadapter
  150.     else-Ifstr(i) $(!NTN_InstallMode) == Update
  151.         set StartLabel = UpgradeSoftware
  152.     else-Ifstr(i) $(!NTN_InstallMode) == bind
  153.         set StartLabel = bindingadapter
  154.     else-Ifstr(i) $(!NTN_InstallMode) == configure
  155.         Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  156.             Debug-Output "Cannot configure the elink II driver software."
  157.             Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
  158.         else
  159.             Debug-Output "Cannot configure the elink II adapter card."
  160.             Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_HARDWARE
  161.         endif
  162.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  163.             Debug-Output "ShellCode error: cannot get an error string."
  164.             goto ShellCodeError
  165.         endif
  166.         set Error = $($R0)
  167.         set from = end
  168.         set to = end
  169.         goto nonfatalinfo
  170.     else
  171.         set StartLabel = installadapter
  172.         set OEM_ABANDON_OPTIONS = {}
  173.         set OEM_ABANDON_SOFTWARE = FALSE
  174.         set OEM_ABANDON_ON = TRUE
  175.     endif
  176.     set from = $(fatal)
  177.     set to = $(fatal)
  178.     goto $(StartLabel)
  179.  
  180. installadapter = +
  181.     OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  182.     Ifstr $(KeyProduct) != $(KeyNull)
  183.         CloseRegKey $(KeyProduct)
  184.         ifstr(i) !(NTN_RegBase) == $(ProductKeyName)
  185.            Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+
  186.                $(ProductVersion)
  187.            ifint $($ShellCode) != $(!SHELL_CODE_OK)
  188.                Debug-Output "ShellCode error: cannot get an error string."
  189.                goto ShellCodeError
  190.            endif
  191.            goto end
  192.         else
  193.            Shell $(UtilityInf), CardExistedDlg
  194.            ifint $($ShellCode) != $(!SHELL_CODE_OK)
  195.                Debug-Output "ShellCode error: cannot get an error string."
  196.                goto ShellCodeError
  197.            endif
  198.            ifstr(i) $($R1) != "OK"
  199.                goto end
  200.            endif
  201.            set OldVersionExisted = $(TRUE)
  202.         endif
  203.     endif
  204.     goto nextstep
  205.  
  206. configureadapter = +
  207.     set Error = "Configure: Not Implmemented yet"
  208.     goto fatal
  209.  
  210. nextstep = +
  211.     StartWait
  212.  
  213. installproduct = +
  214.     Shell $(UtilityInf), MCAFindBus, $(Elink527_1BYTE), $(Elink527_2BYTE)
  215.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  216.         goto ShellCodeError
  217.     endif
  218.     ifstr $($R0) != "NO_ERROR"
  219.         set Error = $($R0)
  220.         goto fatal
  221.     endif
  222.     ifstr(i) $($R1) == {}
  223.         set Error = $(CANNOT_FIND_ANY_CARD)
  224.         set CommonStatus = USER_CANCEL
  225.         set from = "end"
  226.         goto nonfatal
  227.     endif
  228.     set AdapterList = $($R1)
  229.     ifint $(OldVersionExisted) == $(FALSE)
  230.         ifstr(i) $(!NTN_InstallMode) == "install"
  231.            Ifstr(i) $(DoCopy) == "YES"
  232.               Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) YES
  233.               Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  234.                   Goto ShellCodeError
  235.               Else-Ifstr(i) $($R0) == STATUS_FAILED
  236.                   Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
  237.                   ifint $($ShellCode) != $(!SHELL_CODE_OK)
  238.                       goto ShellCodeError
  239.                   endif
  240.                   set Error = $($R0)
  241.                   Goto fatal
  242.               Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
  243.                   Goto successful
  244.               Endif
  245.               Set SrcDir = $($R1)
  246.            Endif
  247.            install "Install-Option"
  248.            ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  249.               Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
  250.               ifint $($ShellCode) != $(!SHELL_CODE_OK)
  251.                   goto ShellCodeError
  252.               endif
  253.               set Error = $($R0)
  254.               goto fatal
  255.            endif
  256.         endif
  257.         Shell $(UtilityInf), AddSoftwareComponent, $(Manufacturer), +
  258.             $(ProductSoftwareName), +
  259.             $(ProductSoftwareName), +
  260.             $(ProductSoftwareTitle), $(STF_CONTEXTINFNAME), +
  261.             $(ProductSoftwareImagePath), "kernel", "NDIS", {}, "",+
  262.             $(NetEventDLL)
  263.         Set OEM_ABANDON_SOFTWARE = TRUE
  264.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  265.             goto ShellCodeError
  266.         endif
  267.         set RegistryErrorIndex = $($R0)
  268.         Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR"
  269.             EndWait
  270.             CloseRegKey $($R1)
  271.             CloseRegKey $($R2)
  272.             CloseRegKey $($R3)
  273.             CloseRegKey $($R4)
  274.             CloseRegKey $($R5)
  275.             goto fatalregistry
  276.         endif
  277.         Set SoftProductKey      = $($R1)
  278.         Set SoftNetRuleKey      = $($R2)
  279.         Set SoftServiceKey      = $($R3)
  280.         Set SoftParameterKey    = $($R4)
  281.         Set SoftLinkageKey      = $($R5)
  282.         set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
  283.                            {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+
  284.                            {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+
  285.                            {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitle)},+
  286.                            {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescription)},+
  287.                            {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+
  288.                            {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  289.         Shell  $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
  290.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  291.             goto ShellCodeError
  292.         endif
  293.         set RegistryErrorIndex = $($R0)
  294.         Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR"
  295.             EndWait
  296.             CloseRegKey $(SoftProductKey)
  297.             CloseRegKey $(SoftNetRuleKey)
  298.             CloseRegKey $(SoftServiceKey)
  299.             CloseRegKey $(SoftParameterKey)
  300.             CloseRegKey $(SoftLinkageKey)
  301.             goto fatalregistry
  302.         endif
  303.         set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareType)},+
  304.                             {use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUse)}, +
  305.                             {bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindForm)}, +
  306.                             {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClass)}, +
  307.                             {bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindable)}, +
  308.                             {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  309.         Shell  $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
  310.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  311.             goto ShellCodeError
  312.         endif
  313.         set RegistryErrorIndex = $($R0)
  314.         CloseRegKey $(SoftProductKey)
  315.         CloseRegKey $(SoftNetRuleKey)
  316.         CloseRegKey $(SoftServiceKey)
  317.         CloseRegKey $(SoftParameterKey)
  318.         CloseRegKey $(SoftLinkageKey)
  319.         Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR"
  320.             EndWait
  321.             goto fatalregistry
  322.         endif
  323.     endif
  324.     ForListDo $(AdapterList)
  325.         set BusNum = *($($),1)
  326.         set SlotNum = *($($),2)
  327.         Debug-Output $(BusNum)
  328.         Debug-Output $(SlotNum)
  329.         Shell $(UtilityInf), IsNetCardAlreadyInstalled, $(BusNum), +
  330.             $(SlotNum), $(ProductHardwareDescription), $(ProductHardwareName)
  331.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  332.             goto ShellCodeError
  333.         endif
  334.         ifstr $($R0) != "NO_ERROR"
  335.             set Error = $($R0)
  336.             goto fatal
  337.         endif
  338.         ifstr(i) $($R1) != "YES"
  339.                 Shell $(UtilityInf), AddHardwareComponent, $(ProductHardwareName),$(STF_CONTEXTINFNAME),$(ProductKeyName)
  340.                 ifint $($R4) != -1
  341.                     Set OEM_ABANDON_OPTIONS = >($(OEM_ABANDON_OPTIONS), $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$($R4))
  342.                 endif
  343.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  344.                     goto ShellCodeError
  345.                 endif
  346.                 set RegistryErrorIndex = $($R0)
  347.                 Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR"
  348.                     EndWait
  349.                     CloseRegKey $($R1)
  350.                     CloseRegKey $($R2)
  351.                     CloseRegKey $($R3)
  352.                     goto fatalregistry
  353.                 endif
  354.                 Set HardNetCardKey      = $($R1)
  355.                 Set HardNetRuleKey      = $($R2)
  356.                 Set HardParameterKey    = $($R3)
  357.                 set AdapterNumber       = $($R4)
  358.                 set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(Manufacturer)},+
  359.                                    {Title,$(NoTitle),$(!REG_VT_SZ),"["$($R4)"] "$(ProductHardwareTitle)},+
  360.                                    {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDescription)},+
  361.                                    {ProductName,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareName)},+
  362.                                    {ServiceName,$(NoTitle),$(!REG_VT_SZ),$($R5)},+
  363.                                    {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  364.                 Shell  $(UtilityInf), AddValueList, $(HardNetCardKey), $(NewValueList)
  365.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  366.                     goto ShellCodeError
  367.                 endif
  368.                 Shell $(UtilityInf), GetBusTypeNum
  369.                 set BusTypeNum = $($R1)
  370.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  371.                     Debug-Output "ShellCode error."
  372.                     goto ShellCodeError
  373.                 endif
  374.                 set NewValueList = {{BusNumber,$(NoTitle),$(!REG_VT_DWORD),$(BusNum)},+
  375.                                 {BusType,$(NoTitle),$(!REG_VT_DWORD),$(BusTypeNum)},+
  376.                                 {MediaType,$(NoTitle),$(!REG_VT_DWORD),1},+
  377.                                 {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(SlotNum)}}
  378.                 Shell  $(UtilityInf), AddValueList, $(HardParameterKey), $(NewValueList)
  379.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  380.                     goto ShellCodeError
  381.                 endif
  382.                 set TempProdName = """"$(ProductHardwareName)$(AdapterNumber)""""
  383.                 set TempBindForm = $(TempProdName)$(NetRuleHardwareBindForm)
  384.                 set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleHardwareType)},+
  385.                                     {bindform,$(NoTitle),$(!REG_VT_SZ),$(TempBindForm)}, +
  386.                                     {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleHardwareClass)}, +
  387.                                     {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  388.                 Shell  $(UtilityInf), AddValueList, $(HardNetRuleKey), $(NewValueList)
  389.                 CloseRegKey $(HardNetCardKey)
  390.                 CloseRegKey $(HardNetRuleKey)
  391.                 CloseRegKey $(HardParameterKey)
  392.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  393.                     goto ShellCodeError
  394.                 endif
  395.          endif
  396.     EndForListDo
  397.     goto writeparameters
  398.  
  399. writeparameters = +
  400.     EndWait
  401.     goto successful
  402.  
  403. bindingadapter =+
  404.     set Error = "Binding: Not Implmemented yet"
  405.     goto fatal
  406.  
  407. removeadapter = +
  408.     Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  409.         Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  410.             $(ProductSoftwareName)
  411.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  412.             Debug-Output "ShellCode error"
  413.             goto ShellCodeError
  414.         endif
  415.         set RegistryErrorIndex = $($R0)
  416.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  417.             goto fatalregistry
  418.         endif
  419.     else
  420.         Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  421.             $(ProductHardwareName), $(!NTN_RegBase)
  422.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  423.             Debug-Output "ShellCode error"
  424.             goto ShellCodeError
  425.         endif
  426.         set RegistryErrorIndex = $($R0)
  427.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  428.             goto fatalregistry
  429.         endif
  430.     endif
  431.     goto end
  432.  
  433. UpgradeSoftware = +
  434.     ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  435.         OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  436.         Ifstr $(KeyProduct) != $(KeyNull)
  437.             GetRegValue $(KeyProduct),"MajorVersion", VersionInfo
  438.             set Version = *($(VersionInfo), 4)
  439.             Split-String $(!NTN_Infname), "\", FilenameList
  440.             QueryListSize ListSize $(FilenameList)
  441.             set !UG_Filename = *($(FilenameList), $(ListSize))
  442.             install "Install-Update"
  443.             ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  444.                 goto fatal
  445.             endif
  446.             SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
  447.             SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}
  448.             ifint $(Version) != $(ProductVersion)
  449.             endif
  450.             CloseRegKey $(KeyProduct)
  451.         else
  452.             goto fatalregistry
  453.         endif
  454.     else
  455.         OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) +
  456.               $(MAXIMUM_ALLOWED) NetworkCardKey
  457.         Ifstr(i) $(NetworkCardKey) != $(KeyNull)
  458.             GetRegValue $(NetworkCardKey),"ServiceName", ServiceNameInfo
  459.             set ServiceName = *($(ServiceNameInfo), 4)
  460.             OpenRegKey $(NetworkCardKey) "" "NetRules" +
  461.                 $(MAXIMUM_ALLOWED) NetRuleKey
  462.             Ifstr(i) $(NetRuleKey) != $(KeyNull)
  463.             else
  464.                 goto fatalregistry
  465.             endif
  466.             CloseRegKey $(NetRules)
  467.             CloseRegKey $(NetworkCardKey)
  468.         else
  469.             goto fatalregistry
  470.         endif
  471.         OpenRegKey $(!REG_H_LOCAL) "" +
  472.               $(!NTN_ServiceBase)"\"$(ServiceName) +
  473.               $(MAXIMUM_ALLOWED) ServiceKey
  474.         Ifstr(i) $(ServiceKey) != $(KeyNull)
  475.             CloseRegKey $(ServiceKey)
  476.         else
  477.             goto fatalregistry
  478.         endif
  479.     endif
  480.     goto end
  481.  
  482. successful = +
  483.     goto end
  484.  
  485. abandon = +
  486.     ForListDo $(OEM_ABANDON_OPTIONS)
  487.         Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  488.             $(ProductSoftwareName), $($)
  489.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  490.             Debug-Output "ShellCode error"
  491.             goto ShellCodeError
  492.         endif
  493.         set RegistryErrorIndex = $($R0)
  494.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  495.             goto fatalregistry
  496.         endif
  497.     EndForListDo
  498.     Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE
  499.         Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  500.             $(ProductSoftwareName), FALSE
  501.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  502.             Debug-Output "ShellCode error"
  503.             goto ShellCodeError
  504.         endif
  505.         set RegistryErrorIndex = $($R0)
  506.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  507.             goto fatalregistry
  508.         endif
  509.     endif
  510.     goto end
  511.  
  512. warning = +
  513.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error)
  514.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  515.         goto ShellCodeError
  516.     endif
  517.     ifstr(i) $($R1) == "OK"
  518.         goto $(to)
  519.     else-ifstr(i) $($R1) == "CANCEL"
  520.         goto $(from)
  521.     else
  522.         goto "end"
  523.     endif
  524.  
  525. nonfatalinfo = +
  526.     Set CommonStatus = STATUS_USERCANCEL
  527.     Set Severity = STATUS
  528.     goto nonfatalmsg
  529.  
  530. nonfatal = +
  531.     Set Severity = NONFATAL
  532.     goto nonfatalmsg
  533.  
  534. nonfatalmsg = +
  535.     ifstr(i) $(Error) == ""
  536.         Set Severity = NONFATAL
  537.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  538.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  539.             goto ShellCodeError
  540.         endif
  541.         set Error = $($R0)
  542.     endif
  543.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), $(Severity), $(Error)
  544.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  545.         goto ShellCodeError
  546.     endif
  547.     ifstr(i) $($R1) == "OK"
  548.         goto $(from)
  549.     else
  550.         goto "end"
  551.     endif
  552.  
  553. fatalregistry = +
  554.     Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex)
  555.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  556.         goto ShellCodeError
  557.     endif
  558.     set Error = $($R0)
  559.     goto fatal
  560.  
  561. fatal = +
  562.     ifstr(i) $(Error) == ""
  563.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  564.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  565.             goto ShellCodeError
  566.         endif
  567.         set Error = $($R0)
  568.     endif
  569.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
  570.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  571.         goto ShellCodeError
  572.     endif
  573.     goto setfailed
  574.  
  575. ShellCodeError = +
  576.     set DlgType      = "MessageBox"
  577.     set STF_MB_TITLE = "Error: "$(FunctionTitle)
  578.     set STF_MB_TEXT  = "Shell Code Error"
  579.     set STF_MB_TYPE  = 1
  580.     set STF_MB_ICON  = 3
  581.     set STF_MB_DEF   = 1
  582.     ui start "Error Message"
  583.     goto setfailed
  584.  
  585. setfailed = +
  586.     set CommonStatus = STATUS_FAILED
  587.     ifstr(i) $(OEM_ABANDON_ON) == TRUE
  588.         set OEM_ABANDON_ON = FALSE
  589.         goto abandon
  590.     endif
  591.     goto end
  592.  
  593. end = +
  594.     goto term
  595.  
  596. term = +
  597.     Return $(CommonStatus)
  598.  
  599. [Install-Option]
  600.     set STF_VITAL = ""
  601.     ifstr(i) $(AddCopy) == "YES"
  602.         AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  603.     endif
  604.     ifstr(i) $(DoCopy) == "YES"
  605.        set !STF_NCPA_FLUSH_COPYLIST = TRUE
  606.        CopyFilesInCopyList
  607.     endif
  608.     ifstr(i) $(DoConfig) == "YES"
  609.     endif
  610.     Exit
  611.  
  612. [Install-Update]
  613.     set STF_VITAL        = ""
  614.     set STF_OVERWRITE    = "VERIFYSOURCEOLDER"
  615.     AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  616.     AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
  617.     set !STF_NCPA_FLUSH_COPYLIST = TRUE
  618.     CopyFilesInCopyList
  619.     exit
  620.  
  621. [Source Media Descriptions]
  622.     1 = "Etherlink/MC 32 Setup Disk"
  623.  
  624. [Signature]
  625.     FileType = MICROSOFT_DRVLIB_FILE
  626. [GetSignature]
  627.     read-syms Signature
  628.     return $(FileType)
  629.  
  630. [ProductType]
  631.     STF_PRODUCT  = Winnt
  632.     STF_PLATFORM = I386
  633.  
  634. [Files-Inf]
  635.     1, oemsetup.inf, SIZE=1000, RENAME=$(!UG_Filename)
  636.  
  637. [Files-Elink527]
  638.     1, Elink527.sys, SIZE=41984
  639.  
  640.  
  641.  
  642.